package com.tom.demo.mapper;


import com.baomidou.dynamic.datasource.annotation.DS;
import com.tom.demo.common.entity.SysMenu;
import com.tom.demo.dto.MenuSearchDto;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Set;

/**
* @author Administrator
* @description 针对表【sys_menu】的数据库操作Mapper
* @createDate 2024-11-18 21:51:23
* @Entity generator.domain.SysMenu
*/
@Mapper
@DS("master")
public interface SysMenuMapper {

    int deleteByPrimaryKey(String id);

    int insert(SysMenu record);

    SysMenu selectByPrimaryKey(@Param("menuId") String menuId);

    int updateByPrimaryKey(SysMenu record);

    Set<String> findByPerms(@Param("userId")String userId);

    List<SysMenu> findByUserId(@Param("userId")String userId);

    List<SysMenu> findByAll();

    List<SysMenu> findByRoleMenus(@Param("roleId")String roleId);

    List<SysMenu> findMenuAll();

    List<SysMenu> findByMenuType(@Param("types") Set<String> types);

    List<SysMenu> findByParentId(@Param("parentId")String parentId);
}
